<?php
class InitUsersSeeder extends Seeder {

    public function run() {
        DB::table('users')->delete();

        $usersData = array(
            array(
                'username' => 'admin',
                'password' => Hash::make('123456'),
                'email' => 'admin@domain.com',
                'role' => 1,
                'firstname' => '',
                'lastname' => '',
                'status' => 'active'
            ),
            array(
                'username' => 'xizhinong',
                'password' => Hash::make('123456'),
                'email' => 'xizhinong@domain.com',
                'role' => 3,
                'firstname' => 'Xi',
                'lastname' => 'Zhinong',
                'status' => 'active'
            ),
            array(
                'username' => 'linhanyang',
                'password' => Hash::make('123456'),
                'email' => 'linhanyang@domain.com',
                'role' => 4,
                'firstname' => 'Lin',
                'lastname' => 'Hanyang',
                'status' => 'active'
            )
        );

        DB::table('users')->insert($usersData);


    }
}
